﻿using System.Diagnostics;

namespace Puppy.Scheduler.Options
{
    /// <summary>
    /// 连接字符串配置
    /// </summary>
    [DebuggerDisplay("ConnectionConfig(Name = {Name}, ConnectionString = {ConnectionString}, AdoNetConstant = {AdoNetConstant})")]
    public class ConnectionOptions
    {
        /// <summary>
        /// 存储配置的名称
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 存储器的连接字符串
        /// </summary>
        public string ConnectionString { get; set; }

        /// <summary>
        /// 这是可选的，只适用于ADO.NET
        /// </summary>
        public string AdoNetConstant { get; set; }

        /// <summary>
        /// 是否使用Json格式存储，默认存储为二进制
        /// </summary>
        public bool UseJsonFormat { get; set; } = false;
    }
}
